<?php



require "database.php";


require "../config/config.php";

$base=new Db($__conf__);

$id=$_POST['id'];

$___r___=$base->doSql('select * from tp_order where id="'.$id.'"');



$___r=[];

if ($___r___) {
	$___r___=$___r___[0];

	$___r=explode(",",$___r___["chwjicity"]);

	$___r___["t_s"]=$___r[0];
	$___r___["t_c"]=$___r[1];
	$___r___["t_q"]=$___r[2];
	$___r=[];

	$___r=explode(",",$___r___["chwshoujiguo"]);
	$___r___["d_s"]=$___r[0];
	$___r___["d_c"]=$___r[1];
	$___r___["d_q"]=$___r[2];
	

	$bfmoney=(int)$___r___["bfmoney"];

	$tp_bao=$base->doSql('select * from tp_bao where id="'.$bfmoney.'"');

	$___r___["bfmoney"]=$tp_bao[0];

	return json([
		"code"=>200,
		"msg"=>"Successful",
		"requestDate"=>date("Y-m-d H:i:s"),
		"data"=>$___r___
	]);
}else{
	return json([
		"code"=>400,
		"msg"=>"System Error",
		"requestDate"=>date("Y-m-d H:i:s"),
		"data"=>null
	]);
}
